package com.ncmmall.domain.business.distribution;

import com.ncmmall.domain.business.goods.Goods;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;

import javax.persistence.*;
import java.sql.Timestamp;

/**
 * 购买指定商品申请经销商
 */
@Entity
@Table(name = "distributor_level_apply_goods")
@Access(AccessType.FIELD)
@Getter
@Setter
@ToString
@EqualsAndHashCode
@Accessors(chain = true)
public class DistributorLevelApplyGoods {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    /**
     * 关联商品
     */
    @OneToOne
    private Goods goods;

    /**
     * 经销商等级
     */
    @OneToOne
    private DistributorLevel distributorLevel;

    /**
     * 创建时间
     */
    private Timestamp createTime;

}
